//
//  Theme.swift
//  hamaton-app
//
//  Created by intyt on 2024/3/21.
//

import Foundation
import UIKit

struct Theme {
    struct Color {

        struct NavigationBar {
            static let tint = UIColor(hex6: 0x404040)
            static let shadow = UIColor(hex6: 0xF1F1F1)
            static let white = UIColor(hex6: 0xFFFFFF)
        }

        struct TabBar {
            static let background = UIColor(red: 0.99, green: 0.99, blue: 0.99, alpha: 1)
            static let shadow = UIColor(red: 0.94, green: 0.94, blue: 0.94, alpha: 1)
            static let itemNormal = UIColor(hex6: 0x7F7F7F)
            static let itemSelected = UIColor(hex6: 0x22A1E0)
        }

        struct Background {
            static let `default` = UIColor(hex6: 0xFFFFFF)
            static let `defaultgray` = UIColor(hex6: 0xF4F4F4)
            static let `main` =  UIColor(hex6: 0x22A1E0)
            static let `maintwo` = UIColor(hex6: 0x347CAF)
            static let `mainthree` = UIColor(hex6: 0x93D2F3)
            static let `success` = UIColor(hex6: 0x67BD09)
            static let `warn` = UIColor(hex6: 0xAF3434)
            static let `tyregray` = UIColor(hex6: 0xDDDDDD)
        }
        
        struct Font {
            static let `default` = UIColor(hex6: 0x333333)
            static let `main` = UIColor(hex6: 0x333333)
        }
        
        
    }

    struct Font {

        /// 字体配置
        ///
        /// - Parameters:
        ///   - ofSize: 尺寸
        ///   - bold: 是否加粗
        /// - Returns: 字体
        static func size(_ ofSize: CGFloat, bold: Bool = false) -> UIFont {
            return bold ? UIFont(name: "PingFang-SC-Semibold", size: ofSize)!: UIFont(name: "PingFang-SC-Regular", size: ofSize)!
        }

        struct NavigationBar {
            static let title = UIFont(name: "PingFang-SC-Regular", size: 18)!
        }
    }

    struct Icon {
        struct NavigationBar {
            static let location = UIImage(named: "Navigation_Location")
            static let checkIn = UIImage(named: "Navigation_check-in")
            static let search = UIImage(named: "Navigation_search")
        }
    }
}
